import request from '@/common/request.js'

// 查询商家行业类别
export function queryIndustryCategories(data) {
	return request({
		adress: "public/queryCodelist?dmid=INDUSTRY_CATEGORY",
		mod: 'POST',
		data: data.data,
		head: {
			"Accept": "*/*",
			'Content-Type': 'application/json',
			"Authorization": uni.getStorageSync('token'),
			"unitCode": "00"
		}
	})
}
// 生成业务ID
export function businessId(data) {
	return request({
		adress: "pFile/businessId",
		mod: 'POST',
		data: data.data,
		head: {
			"Accept": "*/*",
			'Content-Type': 'application/json',
			"Authorization": uni.getStorageSync('token'),
			"unitCode": "00"
		}
	})
}
// 上传文件
export function upload(data) {
	return request({
		adress: "pFile/upload",
		mod: 'POST',
		data: data.data,
		head: {
			"Accept": "*/*",
			'Content-Type': 'application/json',
			"Authorization": uni.getStorageSync('token'),
			"unitCode": "00"
		}
	})
}
// 删除文件
export function delFile(data) {
	return request({
		adress: "pFile/delFile",
		mod: 'POST',
		data: data.data,
		head: {
			"Accept": "*/*",
			'Content-Type': 'application/json',
			"Authorization": uni.getStorageSync('token'),
			"unitCode": "00"
		}
	})
}
// 新增商户
export function merchantAdd(data) {
	return request({
		adress: "merchant/add",
		mod: 'POST',
		data: data.data,
		head: {
			"Accept": "*/*",
			'Content-Type': 'application/json',
			"Authorization": uni.getStorageSync('token'),
			"unitCode": "00"
		}
	})
}
// 查询结算账户类型
export function querySettlementType(data) {
	return request({
		adress: "merchant/querySettlementType",
		mod: 'GET',
		data: data.data,
		head: {
			"Accept": "*/*",
			'Content-Type': 'application/json',
			"Authorization": uni.getStorageSync('token'),
			"unitCode": "00"
		}
	})
}